App({
    onLaunch: function () {
        var that = this;
        //获取手机型号
        wx.getSystemInfo({
            success(res) {
                const model = res.model;
                const modelInclude = ["iPhone X", 'iPhone XR', "iPhone XS", "iPhone XS MAX"];
                var flag = false;//是否X以上机型
                for (let i = 0; i < modelInclude.length; i++) {
                    //模糊判断是否是modelInclude 中的机型,因为真机上测试显示的model机型信息比较长无法一一精确匹配
                    if (model.indexOf(modelInclude[i]) != -1) {
                        flag = true
                    }
                }
                if (flag) {
                    that.BOTTOM_DISTANCE = 32;
                }
            }
        })
    },
    onShow: function () {
        console.log('App Show')
    },
    onHide: function () {
        console.log('App Hide')
    },
    globalData: {
        hasLogin: false
    }
});